package net.bw.realtime.tmall.mapper;

import net.bw.realtime.tmall.bean.SaleDeviceReport;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/*
 * @ Author：liuyawei
 * @ Date：2025-05-28
 */
public interface SaleDeviceStatMapper {

    @Select("SELECT\n" +
            " device_type,\n" +
            " sum(total_amount) AS sale_amount\n" +
            "FROM jtp_tmall_report.dws_device_distribution_report\n" +
            "WHERE toDate(window_start_time) = #{date}\n" +
            "GROUP BY device_type")
    List<SaleDeviceReport> selectSaleAmount(String date);

}
